hey, i am trying to insert multiple checkbox data in my database but having a littlt bit problem. When i am trying to insert checkbox data it inserts only id and nothing else. Here is my full code:- <?php include("config.php"); if(isset($_POST['save'])){ $contact_sms = $_POST['contact_sms']; $check[] = $_POST['check']; $firm_name = $_POST['firm_name']; var_dump($firm_name); $checkbox = $_POST['check']; for($i=0;$i<count($checkbox);$i++){ $bulksms="INSERT INTO bulk_sms (sent_sms,firmname_sms,contact_sms) VALUES('".$checkbox[$i]. "','".$row['firm_name']. "','$contact_sms')"; $smsquery=mysqli_query($conn, $bulksms); } } $sql="SELECT * FROM inventory_details where status ='0' AND role='0' ORDER BY position ASC, role ASC, visiter DESC limit 0,100"; $query=mysqli_query($conn, $sql); ?> <form method="post" action="" id="msform"> <?php $i=0; while($row=mysqli_fetch_assoc($query)){ $id = $row['id']; $firm_name = …

Member Avatar
+0 forum 0

I am facing issues using logical operators to perform operations in SAP HANA. Can anyone help me?

Member Avatar
Member Avatar
+0 forum 1

Please, why I got this error(SQL Error: ORA-00907: missing right parenthesis ) whats wrong in my code? CREATE TABLE DomeniuAB(ID_DOMAB NUMBER(10) constraint ID_DOMAB_PK PRIMARY KEY , DENUMIRE VARCHAR2(20) NOT NULL, DETALII VARCHAR2(20) NOT NULL, ISBNAB_CarteAB VARCHAR2(15), CONSTRAINT ISBNAB_FK FOREIGN KEY (ISBNAB_CarteAB) REFERENCES CarteAB(ISBNAB), CNPAB_AutorAB NUMBER(10), CONSTRAINT CNPAB_FK FOREING KEY (CNPAB_AutorAB) REFERENCES AutorAB(CNPAB));

Member Avatar
Member Avatar
+0 forum 3

Hi group, I'm trying to store the information from a various textboxes into my database. However it is not writing the data (I'm getting my planned error message, "New Record FAILED. Please contact your systems administrator." From the code below, do you see where my error may be? What corrections do I need to make to ensure a successful insert? Dim con As New SqlClient.SqlConnection con.ConnectionString = ("Data Source=(LocalDB)\MSSQLLocalDB;AttachDbFilename=C:\Users\Don\Documents\Visual Studio 2019\SalesForm\DWHRPT.mdf;Integrated Security=True") con.Open() Dim com As New SqlClient.SqlCommand("", con) com.CommandText = "INSERT INTO CUSTREC (CUST_ACCT_NO, CUST_COMPANY_NAME, CUST_LOCATION, CUST_TYPE, CUST_FIRST_NAME, CUST_MIDDLE_INITIAL, CUST_LAST_NAME, CUST_MAIL_ADDRESS1, CUST_MAIL_ADDRESS2, CUST_MAIL_CITY, CUST_MAIL_STATE, CUST_MAIL_ZIP_CODE, CUST_MAIL_ZIP_PLUS4, CUST_CREDIT_LIMIT, CUST_PRIMARY_PHONE, CUST_ALT_PHONE, …

Member Avatar
Member Avatar
+0 forum 4

Hi there here is a stupid question. I have created an update statement that updates a table that has null user id using a name as the identifier: [CODE] UPDATE dembel SET userid = 8908 WHERE [Name] = 'o'reily' [/CODE] However the the name already contains an apostrophe which causes a problem in sql, How can i write the name so that the apostrophe is part of the string itself.

Member Avatar
Member Avatar
+0 forum 4

[MYSQL] my query is:- SELECT * FROM (SELECT 'attendence' AS 'type',userAS 'username', STR_TO_DATE(in_time, '%d-%m-%Y %H:%i:%s') AS 'time_in', 'in_address' AS 'address_in', STR_TO_DATE(out_time, '%d-%m-%Y %H:%i:%s') AS 'time_out', 'out_address' AS 'address_out' FROM attendence UNION ALL SELECT 'visit', username, STR_TO_DATE(visit_time_in, '%d-%m-%Y %H:%i:%s'), location_in, STR_TO_DATE(visit_time_out, '%d-%m-%Y %H:%i:%s'), location_out FROM visits) t WHERE t.username = 'MCCuser0036' AND time_in BETWEEN STR_TO_DATE('01-01-2019', '%d-%m-%Y %H:%i:%s') AND STR_TO_DATE('27-04-2019', '%d-%m-%Y %H:%i:%s') ORDER BY time_in ASC; and result is:- +------------+-------------+---------------------+----------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------------------------------------------+ | type | username | time_in | address_in | time_out | address_out | +------------+-------------+---------------------+----------------------------------------------------------------------------------------------------------------------+---------------------+-----------------------------------------------------------------------------------------------------+ | attendence | MCCuser0036 | 2019-01-25 11:02:09 | in_address | 2019-01-25 11:02:10 | out_address | | visit | …

Member Avatar
Member Avatar
+0 forum 1

I'm writing stored procedure with dynamic sql having dynamic table name as, CREATE OR replace PROCEDURE Pr_get_result (p_table_name IN VARCHAR2, p_object_Id IN VARCHAR2) IS p_prop_code VARCHAR2(50) := 'pH'; BEGIN EXECUTE IMMEDIATE 'DECLARE ' || ' TYPE ObjCurTyp IS REF CURSOR; ' || ' v_obj_cursor ObjCurTyp; ' || ' v_stmt_str VARCHAR2(32000); ' || ' v_obj_record ' || p_table_name || '%rowtype; '|| 'BEGIN ' || ' v_stmt_str := ''SELECT * FROM ( SELECT * FROM '|| p_table_name ||' where CREATED_DATE<= ( SELECT CREATED_DATE FROM '|| p_table_name ||' WHERE object_id='|| p_object_Id ||' AND PROPERTY_CODE='|| p_prop_code || ' ) Order By CREATED_DATE DESC ) …

Member Avatar
Member Avatar
+0 forum 1

Hi, I need help to create a relational database for shop.The database should contain a column for barcode in order to register items and also to read details of items using barcode scanner.Besides this database will contain tables for performing all operations for shopping store items what are those operations I don,t know but I need it for shopping store. Thanks.

Member Avatar
Member Avatar
+0 forum 2

Which SQL data types can be used in SAP HANA?

Member Avatar
Member Avatar
-1 forum 1

Hello i am getting an error on a CASE WHEN THEN syntax on my mySql SELECT DISTINCT u.uid,c.c_id,u.name,u.profile_pic,u.username,u.email,c.time FROM conversation c, users u, conversation_reply r CASE WHEN c.user_one = '99' THEN c.user_two = u.uid WHEN c.user_two = '99' THEN c.user_one= u.uid END AND ( c.user_one ='99' OR c.user_two ='99' ) AND u.status='1' AND c.c_id=r.c_id_fk AND u.uid<>'1'ORDER BY c.time DESC LIMIT 15 #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'CASE WHEN c.user_one = '99' THEN c.user_two = u.uid WHEN c.user_t' at …

Member Avatar
Member Avatar
+0 forum 5

I have a sp which has multiple resultset.I need to create another procedure which should execute the second resultset of 1st sp for ex SP1 gives two resultset I need to write sp2 which uses only the second resulset

Member Avatar
+0 forum 0

I have a sp which has multiple resultset.I need to create another procedure which should execute the second resultset of 1st sp for ex SP1 gives two resultset I need to write sp2 which uses only the second resulset

Member Avatar
+0 forum 0

> Last month, Facebook admitted to storing million of Facebook passwords in plaintext. The Verge Apr 18, 2019 We see students being taught login systems here and a recurring mistake is passwords being stored in databases. It appears that CompSci courses teach bad practices early and as we know it's hard to unlearn what you learn earlier. Further reading seems to indicate these passwords may have collected via logging. "But as Krebs on Security first reported, various errors seem to have caused Facebook’s systems to log some passwords in plain text since as early as 2012." I'm been chided for …

Member Avatar
Member Avatar
+1 forum 1

Hi group, I've just installed Visual Studio 2019 and have started my first app using this. Within the program I created a database using the tools provided in Visual Studio. I now want to begin writing to the tables I've created. But I'm stumped on how to do this. Hopefully you can help. This database is installed on my laptop and is called DATAWHOUSE. Will I need some kind of connection string to write to the data table (and to read from it and/or make changes to it in the future)?

Member Avatar
Member Avatar
+0 forum 2

can we able to count how many number of resultset is returned by a stored procedure? i have a sp which will result in multipe resultset. more then 6.sometime 4 sometime 6 based on the parameters. so i need to count how many resultsets are returned by the sp

Member Avatar
+0 forum 0

I have a table where I want to update "time 2" row, in the user's last "time 1" entry. I was try this, but not function. UPDATE `temp` SET `time2`=NOW() WHERE user = 'kraso' (SELECT max(time1) FROM 'temp')

Member Avatar
Member Avatar
+0 forum 5

Show error when I login to the SQL server management. First, I change the server name. Second restart the server/1st stop services the start services. Then I check the server name SELECT @@servername AS 'ServerName' using this line the show new change server name. Then I closed the window of SQL server then open it and type the new change server but show error. Please help me.... I use SQL Server 2008 r2. Windows authentication [Click Here](https://ibb.co/mzL2BdC) SELECT HOST_NAME() AS 'host_name()', @@servername AS 'ServerName\InstanceName', SERVERPROPERTY('servername') AS 'ServerName', SERVERPROPERTY('machinename') AS 'Windows_Name', SERVERPROPERTY('ComputerNamePhysicalNetBIOS') AS 'NetBIOS_Name', SERVERPROPERTY('instanceName') AS 'InstanceName', SERVERPROPERTY('IsClustered') AS 'IsClustered' EXEC …

Member Avatar
+0 forum 0

In mysql database i created "leave" table: CREATE TABLE `leave` ( `ID_LEAVE` int(11) NOT NULL, `ID_WORKER` int(11) NOT NULL, `BEGIN_DATE` datetime DEFAULT NULL, `END_DATE` datetime DEFAULT NULL ) INSERT INTO `leave` (`ID_LEAVE`, `ID_WORKER`, `BEGIN_DATE`, `END_DATE`) VALUES (3, 26, '2019-03-20 07:00:00', '2019-03-21 15:00:00'), (4, 22, '2019-03-20 07:00:00', '2019-03-20 15:00:00'); "Workers" table: CREATE TABLE `workers` ( `ID_WORKER` int(11) NOT NULL, `FNAME` varchar(20) NOT NULL, `LNAME` varchar(20) NOT NULL ) INSERT INTO `workers` (`ID_WORKER`, `FNAME`, `LNAME`) VALUES (22, 'ALAN', 'FAST'), (23, 'LEON', 'SPEED'), (24, 'ADAM', 'GREEN'), (25, 'DAVID', 'BUCS'), (26, 'JACK', 'FAR'), (27, 'ADAM', 'GAX'), (28, 'ANDREW', 'WORM'); "Orders" table: CREATE TABLE `orders` …

Member Avatar
+0 forum 0

Hello i have a problem with a Sql script `SELECT col1_id, col1_name, col2 FROM table GROUP BY ?????` col1_id col1_name col2 A john bear A john dog A john cat A john bear A john dog A john cat A john dog A john cat A john bear A john dog A john cat A john bear A john dog A john cat A john dog A john cat I want to return all results. It has to return like this: ` echo col1_id . col1_name` (A john) and then `col2` (bear,dog, cat)

Member Avatar
Member Avatar
+0 forum 4

Hi there, recently I have created stored procedure in **Postgres Sql** which deals about with hashing passwords. When used via **pgAdmin** tool it works like a charm as stated below. SELECT horeca_user.update_token( 1, //user_id 1, //type 'sdsfsdfs' //token ) I have also installed extension **pgcrypto**. It works when called via **pgadmin** tool, but not inside **laravel** app as stated below my php code. $token=\DB::select("SELECT * from \"horeca_user\".update_token('$type', '$user_id', '$token')"); and finally this is my procedure code. CREATE OR REPLACE FUNCTION horeca_user.update_token(tp integer,userid integer,token character varying) RETURNS character varying LANGUAGE 'plpgsql' VOLATILE PARALLEL UNSAFE COST 100 AS $BODY$ DECLARE uid INTEGER; …

Member Avatar
+0 forum 0

Hi, How can i make query for this: Table1 Column1 Column2 LS11111 0 LS22222 100 LS33333 10 LS44444 0 LS55555 25 Table2 Column1 Column3 LS11111 100 LS22222 80 LS33333 25 Result i need is Column1 Column2 LS11111 100 LS22222 100 LS33333 25 LS44444 0 LS55555 25 Column1 is same on both tables, Column2 is pieces number in table1, and column3 is pieces number in Table2 I need maximum piece numbers. If table2 doesnt exist column1 value then shows table1 column2, and if it exist and is larger than table1 column2 then shows number from table2

Member Avatar
Member Avatar
+0 forum 4

In Access I want to group and assign data according to conditions with 2 values 0 and 1 (true or false) and with the condition NGAYGIAO>= #01/01/2019# and NGAYGIAO <=# 31/01/2019# me How to write commands ? The data I put in the excel file consists of two sheets: Original data and Result, where Original data is the original data sheet that is the result of the problem I need, when running the access issue, ask you to help me with the problem. http://www.mediafire.com/file/hkkw519bw2k3o9h/baitap_data2.xls/file

Member Avatar
+0 forum 0

Can anyone help me with a SQL string ? or point me in the right direction? I have a colum called ctn_node_path which has results like PARTS & ACCESSORIES > PSJOHNSON - SEDDON JOHNSON PARTS > JN - JOHNSON PARTS I am trying to split the string into three PARTS & ACCESSORIES SJOHNSON - SEDDON JOHNSON PARTS JN - JOHNSON PARTS I am using RTRIM(LEFT (ctn_node_path, CHARINDEX(' > ',ctn_node_path, 0))) to get the first part of the string however getting Function argument count error can anyone help?

Member Avatar
Member Avatar
+0 forum 2

Hello i want to UNION three tables from the same database. SELECT DISTINCT * FROM (SELECT uid as id, name as name, username as username,bio as aboutme, '' as text, 'user' as type, profile_pic as profile_pic, '' as media_pic, '' as group_pic, 'U' as mediatype, '' as image_path FROM users ORDER BY rand() LIMIT 5) AS T UNION ALL (SELECT group_id as id, group_name as name,'' as username, group_desc as aboutme, '' as text, 'group' as type, '' as profile_pic, '' as media_pic, group_pic as group_pic, 'G' as mediatype, '' as image_path FROM groups ORDER BY rand() LIMIT 5) UNION …

Member Avatar
Member Avatar
+0 forum 3

I want to calculate the total conditional in the month but remove the records that are not the same month and not the same year, the condition that eliminates the view on the sql access because the result is true or false in the excel file http://www.mediafire.com/file/kq2mr2v6px1uxan/exercise.rar DOANHTHU2: Sum(IIf(Not IsNull([DONGIA]),[SOLUONG]*([DONGIA]/1000000),[SOLUONG]*([DONGIATT]/1000000))) DOANHTHU2: Sum(IIf(Not IsNull([DONGIA]) AND (SELECT COUNT(*) AS DEM FROM HDMUABAN WHERE (((HDMUABAN.HD)='M1101') AND ((HDMUABAN.LOAIHD)='FBAN') AND ((Month([NGAYGIAO]))=1) AND ((Year([NGAYGIAO]))=2019)) GROUP BY HDMUABAN.HD, HDMUABAN.NGAYGIAO, HDMUABAN.LOAIHD) AS NUM <=0,[SOLUONG]*([DONGIA]/1000000),[SOLUONG]*([DONGIATT]/1000000))) TONGDOANHTHU2: IIf(Not IsNull([DOANHTHU2]) And Not IsNull([BSLN]),[DOANHTHU2]+[BSLN],IIf(IsNull([DOANHTHU2]) And Not IsNull([BSLN]),[BSLN],[DOANHTHU2])) My example only removed one record, I designed the problem of removing many records if …

Member Avatar
+0 forum 0

So I am attempting to do an ER diagram over a login, with just login data, and the base data of the person loggin in, and the connection between login_ID and Basedata/Stamdata_ID. Is this correct, or how would you guys do it? ![53117831_816749895338489_2535073724562931712_n.jpg](/attachments/large/4/592e2722cc6c966e769126c23313ec2e.jpg) http://prntscr.com/mskpli

Member Avatar
Member Avatar
+0 forum 3

Please I'm trying a simple connetivity with VB.Net to Microsoft Access Database and it keeps giving this erro message.... Please i need help Thisis the error it gives The 'Microsft,ACE.OLEBD.12.0' provider is not registered on the local host

Member Avatar
Member Avatar
+1 forum 3

All Time Show Null value Please help me what is the wrong in my code declare @mxdbvlu int declare @dbvlunm int set @mxdbvlu= (select max(Database_name) from TBL_FY_SELECT_1) if @mxdbvlu = null set @dbvlunm=1000 else set @dbvlunm=sum(@mxdbvlu+1) select @dbvlunm,@mxdbvlu

Member Avatar
Member Avatar
+0 forum 1

Hi Pobably it is going to be repeated question but I wasnt able to find such thread. I just would like to do sql through C++ and I have 2008 ms database. What are free libraries available for doing such job? Thanks

Member Avatar
Member Avatar
+0 forum 3

Sir I have this data ![Untitledg_jygukg.png](/attachments/large/4/e33bd064d12c1ff9b76646dc9376d4de.png) Group by hours Or First value of every hour Please help

Member Avatar
Member Avatar
+0 forum 2

The End.