im trying to compare a text field on my form to a colum in my mysql table if its one of the codes then submit the form if it isnt then display alert window? im new to php
any examples or tutorials on my code above?
thanks
Pete
ok heres what i did and this does nothing. i know i have some syntax errors plaease help thanks
test.sh
#!/bin/bash
date='date +%Y%m%d%H%M%S'
file= "$date.txt"
cat /usr/etc/referral.sql | sed -e "s/file/$file/g" |/usr/bin/mysql -u root ehpadmin
referral.sql
SELECT * INTO OUTFILE '/tmp/file'...
Below is my test.sh and my referral.sql now i want the .txt file to be named
the systemdate and the timestamp .txt
ex 20051009235959.txt somthing like that
test.sh
#!/bin/bash
/usr/bin/mysql -u root ehpadmin </usr/etc/referral.sql
referral.sql
SELECT * INTO OUTFILE '/tmp/referral.txt'...
well this is what i have
c:\mysql\bin\mysqldump -h localhost -u root --tab=C:\temp\referrals\ --fields-terminated-by=";" --lines-terminated-by="\n" --no-create-info ehpadmin referral_authorization
and this is what it returns:
MOMC0394651;MANOKIAN GHARGH, ARSINEH;F;19830811;26 RIBVERA...
tony almost their. This writes no file????
my.sh file
#!/bin/bash
/usr/bin/mysql -h localhost -u root < /usr/etc/referral.sql
referral.sql
select * into outfile '/usr/etc/referral.txt' fields terminated by ';' from ehpadmin.Referral_Authorization
well this is my output and tony thanks for helping hopefully we can solve this. this is what the output....
why is it showing me all this garbage??? im using
i have full privildges
code:
#!/bin/bash
usr/bin/mysqldump -h localhost -u root --tab--fields-terminated-by=';'...
Ok i cant get it to work here is my full script. I just want to write my table data to a csv file. Could i have a example based on my full script??? thanks
#!/bin/bash
/usr/bin/mysql -h localhost -u root ehpadmin < /usr/etc/scripts/script.sql
/usr/bin/mysqldump -h localhost -u root ehpadmin...
if you look at the above thats what im getting. In windows i use the same script and i get a flat csv file of data???? dont understand why im getting all that code
this code dosent works, it dosent even write the file???
/usr/bin/mysqldump -h localhost -u root --tab=/usr/etc/scripts/...
i have one record in their this is what my file reproduces:
using
/usr/bin/mysqldump -h localhost -u root --no-create-info ehpadmin Referral_Authorization > Referral.txt
almost their lil help please thanks
-- MySQL dump 10.9
--
-- Host: localhost Database: ehpadmin
--...
Yes localhost in both cases. the reason why i have the \ is becuas eim goign onto a new line. DO i need that ????
im new to linux. So right now it just writes a blank file, no data in it??? ANy reasons why???? or do i have it set up wrong?
i have fedora core 4 installed. i have a script that extracts data from one table to the next. now this script works fine in windows but in linux it writes the file but theirs no data in it???
much help needed thanks
/usr/bin/mysqldump -h localhost -u root --tab=/usr/etc/scripts/...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.