User Profile
Collapse
-
no the code is vb6 no php. the vb6 code needs changing from a access database to mysql database -
Sorry im a php coder not a VB6 coder. I was wondering if you could be a little more specific? any links for this would be appreciated.
ThanksLeave a comment:
-
help with changing code from access to mysql database
Hi
I have a caller ID software that I would like to change from Microsoft Access database to Mysql and was wondering if somebody could help me. The code i currently have is:
[code=vb6]
Private Sub OpenDataBase()
Set fo = New FileSystemObjec t
Set wrk = CreateWorkspace ("", "admin", "", dbUseJet)
If Not fo.FileExists(m _stDataPath & "callerid.m db")... -
LOL yes, definatly haha its the best pizza in town :o)
hehe
if you dont mind, tomorrow I will post you the total.php
basically im having problems in removing a single row from the order_total tableLeave a comment:
-
ok i will get the code to you tomorrow if thats ok? getting a little late now :o(
thank you again for helping me out so rapidly. You should be in a programming job :o)Leave a comment:
-
so, whats your thoughts on retreiving the array and seporating each line using the comma. do you think the explode function is the best way forward for this?Leave a comment:
-
ha, you should see my database.sql text for creating the tables LOL
theres about 15 tables or so.Leave a comment:
-
I bet your right, as im new i bet i could probily cut half the code down to achully what i am using. ive been working on it for nearly 2 months now, and have learnt a lot, well not enough to overcome your help with was greatfully received :o) I dont mind, i think you would probily laugh at the amount of if and else if statements im using,LOL.
I would like to add you to my Buddy's list of thats ok with you? how would you want me to...Leave a comment:
-
i added a ',' at the end of the $newValue so that each entry into the table field would be seporated with a , as shown as :
[php]
$newValue .= $row['item'] .= $row['cost'].=',';
[/php]
My next stage would be then to retreive the string as a whole and use the explode function to seporate each entry via a comma.
would it be something like
[php]
explode(',', $row['item']);...Leave a comment:
-
wow its worked, array fully entered into the table with no errors. Your a star :o)
sorry im new to php ;o)Leave a comment:
-
sorry im new to php programming and im not too sure what you mean. If i remove the . after the $newValue it only inserts the last value in the array, if i keek the . after the $newValue it inserts the entire array but displays the error message i posted in the previous postLeave a comment:
-
very strange. it does insert but i get an error message on line 7 when I add the . after the $newValue
[php]
$newValue .= $row['item'] .= $row['cost'];
[/php]
error message receive
PHP Notice: Undefined variable: newValue in C:\Inetpub\wwwr oot\takeaway\te stinsertitems.p hp on line 7
although it does insert it into the table. how can I not get this error message to appear?Leave a comment:
-
-
ok
moved the sql statement out of the link and changed the $newValue within the loop to:
[php]
$newValue = $row['item'] .= $row['cost'];
[/php]
still only inserts the last entry in the array :o(Leave a comment:
-
sure
this is a var_dump of the sql query out of the while loop
string(109) "UPDATE orders_complete SET ord_descr='Hlf lb Chicken burger3.50, ' WHERE date='06/11/08' and time='13:33:53' "
below shows a var_dump of the sql statement within the while loop
string(109) "UPDATE orders_complete SET ord_descr='9 Inch Seafarer Pizza8.00, ' WHERE date='06/11/08' and time='13:33:53' "...Leave a comment:
-
Hi thanks for such a quick responce.
I have removed the comma and placed the sql update statement outside the while loop. Didnt seem to make a difference. The update query entered the last array value. also if you do a [php]print_r($variab le);[/php] this also shows the last item in the array. been trying to get my head around this for 2 days now :o(Leave a comment:
-
help in sending php array to mysql table
I was wondering if somebody could help me. this is driving me crazy.
I am trying to send an array from a mysql_fetch_ass oc result from table total_orders to table orders_complete . I have the following code:
[php]
<?php include("config .php");$sql = "SELECT item, cost FROM orders_total";$ result = mysql_query($sq l) or die(mysql_error ()); while($row = mysql_fetch_ass oc($result)) { $newValue...
No activity results to display
Show More
Leave a comment: