close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Recordsets Breaking?

Thread began 1/12/2011 8:57 pm by Andrew Read | Last modified 1/13/2011 10:17 am by Jason Byrnes | 681 views | 1 replies |

Andrew Read

Recordsets Breaking?

Hello,

I am having a problem with DataAssist created Recordsets damaging themselves by adding un-necessary code, see below:

php:
$Paramdummy_WADAdummy = "-1";
if (isset($_GET['dummy_ID'])) {
  $Paramdummy_WADAdummy = (get_magic_quotes_gpc()) ? $_GET['dummy_ID'] : addslashes($_GET['dummy_ID']);
}
$Paramdummy_ID_WADAdummy = "-1";
if (isset()) {
  $Paramdummy_ID_WADAdummy = (get_magic_quotes_gpc()) ?  : addslashes();
}
mysql_select_db($database_wtse_adm, $wtse_adm);
$query_WADAdummy = sprintf("SELECT dummy_ID, dummy_name, dummy_start, dummy_length FROM dummy WHERE dummy_ID = %s", GetSQLValueString($Paramdummy_ID_WADAdummy, "int"));
$WADAdummy = mysql_query($query_WADAdummy, $wtse_adm) or die(mysql_error());
$row_WADAdummy = mysql_fetch_assoc($WADAdummy);
$totalRows_WADAdummy = mysql_num_rows($WADAdummy);



As you can see additional variable names are being added, in fact when I open this recordset again, it adds another "$Paramdummy_WADAdummy" variable without the get variable in it.

Has anyone else experienced this?

Sign in to reply to this post

Jason ByrnesWebAssist

This is an issue with column names that use the underscore naming convention.

The problem arises from the way that DataAssist creates parameter names in the recordsets and the way that Dreamweaver interperate's them.

Detailed Explanation:
DataAssist uses the column name as the parameter name, the naming convention used is:
Param<column name>

For instance the column name:
dummy_ID

gets a parameter named
Paramdummy_ID


when the code is written for the parameter, the naming convention is:
$<Parameter Name>_<Recordset Name>

So the Paramdummy_ID for the WADAdummy recordset would be written to code as:
$Paramdummy_ID_ WADAdummy

The problem is the way Dreamweaver interperates this parameter name when you reinspect the recordset. Dreamweaver sees everything after the first underscore character as being the recordset name.

This means that Dreamweaver sees the parameter name as:
Paramdummy

and the recordset name as:
ID_ WADAdummy


We are working on trying to fix this issue, in the mean time, you can do one of 2 things to combat the problem:

1) use the camelCase naming convention for your database column instead of underscores - This would be the simplest.

2) Edit the code directly to remove the underscores from the parameter name, for example, edit the parameter name code:
$Paramdummy_ID_ WADAdummy

to:
$ParamdummyID_ WADAdummy

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...