The title says it all, really. The message error I get is the following one:

# Notice: Undefined index: datetime:normal in DatabaseSchema_mysql->processField() (line 201 of /var/www/sitename/cms/drupal-7.0-beta2/includes/database/mysql/schema.inc).
# Notice: Undefined index: datetime:normal in DatabaseSchema_mysql->processField() (line 201 of /var/www/sitename/cms/drupal-7.0-beta2/includes/database/mysql/schema.inc).
# PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT NULL COMMENT 'Date/time of the last click', `last_status` CHAR(4) DEFAU' at line 5: CREATE TABLE {weblinks} ... (continues with full table description)

Comments

Mac Ryan’s picture

Title: Web Links fails to install on D7 b2 » Web Links fails to install on D7 beta 2 (UPDATE: and beta 3 too!)
Mac Ryan’s picture

Title: Web Links fails to install on D7 beta 2 (UPDATE: and beta 3 too!) » Web Links fails to install on D7 beta 3
Anticosti’s picture

Unfortunetly.... Same issue over a fresh rc2 install :(

deep-silver’s picture

weblinks.install

you need to replace all

'type' => 'datetime'

to

'mysql_type' => 'datetime'

while in this file you will also need to change line 463

while ($obj = db_fetch_object($result)) {

to

while ($obj = db_fetch_array($result)) {

else drupal will show you an error while trying to uninstall the module

shunting’s picture

For D7.0:

The change to myql_type works on mysql, but the result at 463 is an object, so db_fetch_array wouldn't be right and isn't in D7 anyhow. This works:

  foreach ($result as $obj) {
    node_delete($obj->nid);
  }

And then around 472 make this change:

   $result = db_query("SELECT v.name FROM {variable} v WHERE v.name LIKE ('weblinks_filter_%')");
  //while ($name = db_result($result)) {
  //  variable_del($name);
  //}
  foreach ($result as $obj) {
    node_delete($obj->name);
  }
shunting’s picture

Also for D7.0, line 7 should be commented out or removed:

  // $result = drupal_install_schema('weblinks');

Because otherwise the installer will complain about the table being installed twice.

That's because:

function weblinks_schema() 

is hook_schema and installs the schema automagically,

shunting’s picture

D7: FILTER_FORMAT_DEFAULT should be replaced by filter_fallback_format() where found.

http://api.drupal.org/api/drupal/modules--filter--filter.module/constant...

Anticosti’s picture

Hmm... with the above tweaks, I still can't install WebLinks on D7.0
Could anyone please post a working patch?

Thanks in advance ;-)

rocky007’s picture

Same issue.....

ballombert’s picture

Work fine for me after :
replacing all
'type' => 'datetime'
by
'mysql_type' => 'datetime'

and then around 472 make this change:

   $result = db_query("SELECT v.name FROM {variable} v WHERE v.name LIKE ('weblinks_filter_%')");
  //while ($name = db_result($result)) {
  //  variable_del($name);
  //}
  foreach ($result as $obj) {
    node_delete($obj->name);
  }
Christopher Riley’s picture

Is this module still being actively developed. I have a client that would love to upgrade to D7 however they use this module extensively and I want to check the status of it as it seems nothing has been done for weeks.

Starminder’s picture

subscribe - just getting it to install cleanly on a new build would be nice.

Is there any temporary workaround to NOT having weblinks, yet...posting a list of links?
I sure miss this module.

bib_boy’s picture

subscribe - any news on this module. We're all moving to Drupal 7 these days and will have to ditch this module which would be a shame.

Starminder’s picture

i miss this module :/

Juan C’s picture

Subscribe.

Taxoman’s picture

Title: Web Links fails to install on D7 beta 3 » Web Links fails to install on D7

The D7 version of this module seems to be unusable at the moment.
(Just marked #1152852: Weblinks fails completely with WSOD and many errors after Upgrade to Drupal 7 as a duplicate of this one, and there is another similar issue related to PostgreSQL in the queue too.)

I am aware of the "Links Package" module, which is more sophisticated.
That one has an old request about merging it with the CCK links module.
See http://drupal.org/node/202599#comment-4984098

Now this very Weblinks module is obviously also in need of some more love, while we now have fields in core; isnt it now possible to do most of this in core? If so, a merge may be even both easier and sensible.

Perhaps this module should provide a way to convert old Weblinks data to a content type with fields in D7?
That would be a separate feature request, but as this module currently seems entirely useless on D7, I would like to hear some feedback on just this here in this thread.

shunting’s picture

Unfortunately, Links Package does not list a D7 version.

I tried installing it, and as of D7.8, creating a web links node doesn't give you a title or a body...

syscrusher’s picture

I'm working on a D7 version of the Links package. It's a pretty major recoding effort, but I use Links actively on multiple sites, so it is definitely going to happen. My day job has kept me from having a lot of Drupal development time lately, unfortunately, but I can't upgrade my own sites until Links is updated, so you don't have to worry about lack of commitment. Just understand it's a major effort an not going to be done overnight.

Strategically, it is my intent to require CCK and to replace the existing "weblink" node type in Links with a CCK-based node type. That goal is part of what's making this update such a large effort. I am hoping to leverage a lot of CCK in the D7 version of Links, for more flexibility. There will be an automated migration process for links defined in the D6 version, of course.

Syscrusher

SharonD214@aol.com’s picture

I tried making the changes as in #10 and then uninstalling but I can't get weblinks blocks to uninstall. I get the following:

PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'dbname.blocks' doesn't exist: DELETE FROM {blocks} WHERE module = 'weblinks_blocks'; Array ( ) in weblinks_blocks_uninstall() (line 59 of .../public_html/sites/all/modules/weblinks/contribs/weblinks_blocks/weblinks_blocks.install)

So weblinks will not uninstall without removing the weblinks blocks module first.

Any ideas?

Thanks
Sharon

SharonD214@aol.com’s picture

ok, removing the entire module and reloading with corrections as in #10 and #7 in all places in weblinks files as well as changing all instances of

db_result(db_query({...}))
to:
db_query({...})->fetchField();

as seen here - http://api.drupal.org/api/drupal/includes--database.pgsql.inc/function/d...

I can now see the weblinks admin page (general settings) but on the actual links page I get the following:
Error

The website encountered an unexpected error. Please try again later.
Error message
Notice: Undefined index: path in weblinks_init() (line 91 of .../public_html/sites/all/modules/weblinks/weblinks.module).
Notice: Undefined index: path in weblinks_init() (line 91 of .../public_html/sites/all/modules/weblinks/weblinks.module).
PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'datatable.vocabulary' doesn't exist: SELECT vid FROM {vocabulary} WHERE module='weblinks'; Array ( ) in _weblinks_get_vocid() (line 192 of .../public_html/sites/all/modules/weblinks/weblinks.module).

As well as the theming is messed up.

Has anyone seen this?
Sharon

Colin @ PCMarket’s picture

Hi guys...

just wondering if the D7 build is still maintained at all

nancydru’s picture

Status: Active » Closed (duplicate)

At the moment there is no real "D7 build" - it is just a non-functional branch. Therefore, this issue is a duplicate of #1362878: Port Weblinks to D7.