SQL

SQL

Hello Sir,

Can u please tell me how to store an image path or image name in Access 2003 Database.

Actuall i stored an image in database but it get stores in this way .ong.binary data.

But i want to store with a filename or path name how can i do this please reply me????


Thankyou sir.



Place Ad.jsp
<%@page import="java.sql.*"%>
<%@page import="java.io.*"%>
<%@page import="java.lang.*"%>
<%
Connection con=null;
Statement stmt=null;
int Num=0;
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
con=DriverManager.getConnection("jdbc:odbc:Advdsn");
stmt=con.createStatement();
ResultSet no=stmt.executeQuery("select OrderNo from OrderTab ");

while(no.next())
{
int Ono=no.getInt("OrderNo");
Num=Ono+1;
}
}
catch(SQLException se){
out.println("Database Error:"+se.getMessage());
}
catch(Exception e){
e.toString();
}
%>
<html>
<head>

<script src="City.js"></script>
<script language="Javascript">

function Calculate()
{
<!--Front Page-->
var fpval;
var cityamt;
var newspaper;
var sizeval;
var city = document.form.city.value;
var noofwd = document.form.Count.value;
var nofw = document.form.Count.value;
var payat = document.form.Total;

<!--Andhra Pradesh-->
if (city.toUpperCase() == "HYDERBAD")
{cityamt = 450;}
else if (city.toUpperCase() == "VISAKHAPATNAM")
{cityamt = 300;}
else if (city.toUpperCase() == "VIJAYAWADA")
{cityamt = 200;}

<!--Bihar-->
if (city.toUpperCase() == "BIHAR")
{cityamt = 500;}

<!--Delhi-->
if (city.toUpperCase() == "DELHI")
{cityamt = 1000;}

<!--Gujarat-->
if (city.toUpperCase() == "AHMEDABAD")
{cityamt = 600;}
else if (city.toUpperCase() == "VADODARA")
{cityamt = 400;}
else if (city.toUpperCase() == "SURAT")
{cityamt = 300;}
else if (city.toUpperCase() == "GANDHINAGAR")
{cityamt = 200;}

<!--Haryana-->
if (city.toUpperCase() == "CHANDIGARH")
{cityamt = 400;}
else if (city.toUpperCase() == "GURGAON")
{cityamt = 300;}

<!--Himachal Pradesh-->
if (city.toUpperCase() == "SHIMLA")
{cityamt = 500;}
else if (city.toUpperCase() == "KULLU")
{cityamt = 400;}
else if (city.toUpperCase() == "MANALI")
{cityamt = 400;}

<!--Jammu and Kashmir-->
if (city.toUpperCase() == "JAMMU")
{cityamt = 600;}
else if (city.toUpperCase() == "SRINAGAR")
{cityamt = 600;}

<!--Karnataka-->
if (city.toUpperCase() == "BANGALORE")
{cityamt = 800;}
else if (city.toUpperCase() == "MYSORE")
{cityamt = 600;}
if (city.toUpperCase() == "MANGALORE")
{cityamt = 400;}
else if (city.toUpperCase() == "UDUPI")
{cityamt = 300;}

<!--Maharastra-->
if (city.toUpperCase() == "MUMBAI")
{cityamt = 1000;}
else if (city.toUpperCase() == "PUNE")
{cityamt = 120;}
else if (city.toUpperCase() == "NASIK")
{cityamt = 240;}
else if (city.toUpperCase() == "NAGPUR")
{cityamt = 360;}

<!--Rajasthan-->
if (city.toUpperCase() == "AJMER")
{cityamt = 400;}
else if (city.toUpperCase() == "JAIPUR")
{cityamt = 500;}
else if (city.toUpperCase() == "JODHPUR")
{cityamt = 300;}
else if (city.toUpperCase() == "BIKANER")
{cityamt = 300;}
else if (city.toUpperCase() == "UDAIPUR")
{cityamt = 300;}

<!--TamilNadu-->
if (city.toUpperCase() == "CHENNAI")
{cityamt = 1000;}
else if (city.toUpperCase() == "THANJAVUR")
{cityamt = 400;}
else if (city.toUpperCase() == "COIMBATORE")
{cityamt = 500;}
else if (city.toUpperCase() == "RAMESHWARAM")
{cityamt = 400;}
else if (city.toUpperCase() == "TRICHY")
{cityamt = 500;}

<!--Uttar Pradesh-->
if (city.toUpperCase() == "AGRA")
{cityamt = 400;}
else if (city.toUpperCase() == "LUCKNOW")
{cityamt = 300;}
else if (city.toUpperCase() == "VARANASI")
{cityamt = 300;}
else if (city.toUpperCase() == "ALLAHABAD")
{cityamt = 300;}

<!--West Benegal-->
if (city.toUpperCase() == "KOLKATA")
{cityamt = 1000;}
else if (city.toUpperCase() == "DARJEELING")
{cityamt = 400;}

<!--Mumbai Mirror-->
var mmval;
if(!document.form.MM.checked) {
mmval = 0
}
else
{
mmval = wordrate(730, 130, nofw);
}


<!--TOI-->
var tival;
if(!document.form.TOI.checked) {
tival = 0
}
else
{
tival = wordrate(2360, 400, nofw);
}


<!--ET-->
var etval;
if(!document.form.ET.checked) {
etval = 0
}
else
{
etval = wordrate(950, 200, nofw);
}


<!--Midday-->
var meval;
if(!document.form.ME.checked) {
meval = 0
}
else
{
meval = wordrate(500, 20, nofw);
}

<!--Hindustan Times-->
var htval;
if(!document.form.HT.checked) {
htval = 0; }
else
{
htval = wordrate(300, 50, nofw);
}

<!--DNA-->
var dval;
if (!document.form.DNA.checked) {dval =0;}
else
{
dval = wordrate(600, 75, nofw);
}

<!--Indian Express-->
var ieval;
if (!document.form.IE.checked) {ieval = 0;}
else
{
ieval = wordrate(160, 15, nofw);
}

<!--Color-->
var colval;
if (!document.form.col.checked) { colval = 0;}
else { colval = 1000;}

<!--B&W-->
var bwval;
if (!document.form.bw.checked) { bwval = 0;}
else { bwval = 500;}


<!--img-->
var imgrate;
if(!document.form.img.value) {imgrate = 0;}
else {imgrate = 200;}


<!--size-->


if (form.size.options[form.size.selectedIndex].text == "3*3")
{ sizeval = 100;}
if (form.size.options[form.size.selectedIndex].text == "3*5")
{ sizeval = 200;}
if (form.size.options[form.size.selectedIndex].text == "4*1")
{ sizeval = 300;}
if (form.size.options[form.size.selectedIndex].text == "4*4")
{ sizeval = 400;}

if (!document.form.fp.checked) { fpval = 0;}
else { fpval = 1000;}

<!--Back Page-->
var bpval;
if (!document.form.bp.checked) { bpval = 0;}
else { bpval = 800;}

<!--Page2-->
var p2val;
if (!document.form.p2.checked) { p2val = 0;}
else { p2val = 600;}

<!--Page3-->
var p3val;
if (!document.form.p3.checked) { p3val = 0;}
else { p3val = 400;}

<!--Page5-->
var p5val;
if (!document.form.p5.checked) { p5val = 0;}
else { p5val = 200;}

<!--Page7-->
var p7val;
if (!document.form.p7.checked) { p7val = 0;}
else { p7val = 100;}

var pageval;
pageval = fpval+bpval+p2val+p3val+p5val+p7val;
payat.value = cityamt+mmval+tival+etval+meval+htval+dval+ieval+sizeval+colval+bwval+pageval+imgrate;

}

function wordrate(baserate, extrarate, numberofwords)
{
var extwrds;
var totrate;
totrate = baserate;

if (numberofwords > 15)
{
extwrds = numberofwords - 15;
}
for (i=0; i<extwrds; i++)
{
totrate = totrate + extrarate;
}
return totrate;
}

function Draft(text1,text2){
var v1=text1.value;
var v = 0;
v2=v1.replace(/\s/g,' ');
v2=v2.split(' ');
for (i=0; i<v2.length; i++) {if (v2[i].length > 0) v++;}
text2.value=v;
}
function checkPhoneNo(num){
if(isNaN(num)){alert("Invalid Phone Number. The only characters permitted are 0 to 9"); return 0;}
else{return 1;}
}
function Validate()
{
var phone=document.form.PhoneNo;
var email=document.form.Email;
if(email.value=="")
{ alert("Please enter valid Email Id");
return false;
}
apos=email.value.indexOf("@")
dotpos=email.value.lastIndexOf(".")
if (apos<1 || dotpos-apos<2)
{
alert("Invalid Email Id")
email.value=="";
email.focus();
return false;
}

if((phone.value=="")||(phone.value==null))
{ alert("Please enter valid PhoneNo");phone.focus();
return false;
}
if (checkPhoneNo(phone.value)==false){
phone.value="";
phone.focus();
return false;
}
if ((phone.value.length==8)||(phone.value.length==10)){
return true;
}
else{
alert("Phone Number must be of 8 numbers or 10 numbers");
return false;
}
return true;
}

</script>
</head>
<% String OrNum=request.getParameter("ordernum"); %>
<body bgcolor="lightblue">
<marquee behavior="alternate" scrollamount=5 scrolldelay=10><h1><font size=4 face="Stroustroup" color="#993355">Advertisement Management System</h1></font></marquee><br>
<p align=center><b> <font color="669933" size=4>Create Ad </font></b></p><br>

<form name="form" method="post" action="Preview.jsp" onsubmit="return Validate();">
<table>
<!--<tr><td style="text-align:left;">OrderNo:</td><td style="text-align:left;"><input type=text name="OrderNo" id="OrderNo" value="<%=OrNum%>" readonly></td></tr>-->
<tr>
<td style="text-align: left;">State:</td>
<td style="text-align: left;">
<select name="State" id="state" onchange="setCities();">
<option value="Andhra Pradesh">Andhra Pradesh</option>
<option value="Bihar">Bihar</option>
<option value="Delhi">Delhi</option>
<option value="Gujarat">Gujarat</option>
<option value="Haryana">Haryana</option>
<option value="Himachal Pradesh">Himachal Pradesh</option>
<option value="Jammu and Kashmir">Jammu and Kashmir</option>
<option value="Karnataka">Karnataka</option>
<option value="Maharashtra">Maharashtra</option>
<option value="Rajasthan">Rajasthan</option>
<option value="TamilNadu">TamilNadu</option>
<option value="Uttar Pradesh">Uttar Pradesh</option>
<option value="West Benegal">West Benegal</option>
</select>
</td>
</tr><tr>
<td style="text-align: left;">City:</td>
<td style="text-align: left;">
<select name="City" id="city">
<option value="">Please select a State</option>
</select>
</td>
</tr>
<tr>
<td style="text-align: left;">Main Category:</td>
<td style="text-align: left;">
<select name="mainCat" id="mainCat" onchange="setCategory();">
<option value="Electronics & Technology">Electronics & Technology</option>
<option value="Home & Lifestyle">Home & Lifestyle</option>
<option value="Real Estate">Real Estate</option>
<option value="Cars & Bikes">Cars & Bikes</option>
<option value="Jobs">Jobs</option>
<option value="Services">Services</option>
<option value="Entertainment">Entertainment</option>
<option value="Pets and Pet Care">Pets and Pet Care</option>
<option value="Community">Community</option>
<option value="Events">Events</option>
<option value="Matrimonial">Matrimonial</option>

</select>
</td>
</tr><tr>
<td style="text-align: left;">Sub Category:</td>
<td style="text-align: left;">
<select name="subCat" id="subCat">
<option value="">Please select a Main Category</option>
</select>
</td>
</tr>
<tr><td>Title:</td><td> <input type=text name="Title" size=25 ></td></tr>
<tr><td>Draft Your Ad here:</td><td><textarea name="DraftAd" cols="15" rows="2" onkeyup="Draft(this,document.form.Count)"></textarea></td></tr>
<tr><td>No of words:</td><td><input name="Count" type="text" value="0" onkeyup="Draft(document.form.DraftAd,this)" readonly></td></tr>
<tr><td>Image:</td><td><input type="file" name="img"></td></tr>
<tr><td>Email:</td><td><input type=text name="Email" size=25></td></tr>
<tr><td>Phone No:</td><td><input type=text name="PhoneNo" size=25 maxlength=10></td></tr>
</table>
<hr color=green>
<p align=center><b> <font color="669933" size=4>Schedule </font></b></p><br>

<table>
<tr><td>Select Newspaper:</td></tr>
<tr><td><input type=checkbox name=NP value="Times of India" id="TOI">Times of India</td>
<td><input type=checkbox name=NP value="Mumbai Mirror" id="MM">Mumbai Mirror</td>
<td><input type=checkbox name=NP value="Economic Times" id="ET">Economic Times</td></tr>
<tr><td><input type=checkbox name=NP value="Hindustan Times" id="HT">Hindustan times</td>
<td><input type=checkbox name=NP value="DNA" id="DNA">DNA</td>
<td><input type=checkbox name=NP value="Indian Express" id="IE">Indian Express</td></tr>
<tr><td><input type=checkbox name=NP value="Midday English" id="ME">Midday English</td>

<tr><td>Ad Size:</td><td><select name="size" size=1>
<option value="3*3">3*3</option>
<option value="3*5">3*5</option>
<option value="4*1">4*1</option>
<option value="4*4">4*4</option>
</select></td></tr>
<tr><td>Select Color or B&W: <input id="col" type="radio" name="COLBW" value="Color">Color</td>
<td><input id="bw" type="radio" name="COLBW" value="BW">B & W</td></tr>

<tr><td>Select Your Date:</td><td><select name="day" size=1>

<%for (int date=1;date<=31;date++)
{
%>
<option value="<%=date%>"><%=date%></option>
<%}%>
</select></td></tr>
<tr><td>Month:</td><td><select name="Month" size=1>
<%
for (int month=1;month<=12;month++){
%>
<option value="<%=month%>"><%=month%></option>
<%}%>
</select></td></tr>
<tr><td>Year:</td><td><select name="Year" size=1>
<%
for (int year=2010;year<=2050;year++){
%>
<option value="<%=year%>"><%=year%></option>
<%}%>
</select></td></tr>

</table>
<hr color=green>
<p align=center><b> <font color="669933" size=4>Payment </font></b></p><br>
<p><b><font color="#336633">Premium Position</font></b></p><br>
<input type=radio name=Page id=fp value="FrontPage">FrontPage<br>
<input type=radio name=Page id=bp value="BackPage">BackPage<br>
<p><b><font color="#336633">Other Premium Pages</font></b></p><br>
<input type=radio name=Page id=p2 value="Page2">Page 2<br>
<input type=radio name=Page id=p3 value="Page3">Page 3<br>
<input type=radio name=Page id=p5 value="Page5">Page 5<br>
<input type=radio name=Page id=p7 value="Page7">Page 7<br><br>
Select Number of Days:</td><td><input type=text name="numDays" size=5><br>

Total Cost:<input type=text name=Total onClick="Calculate()" size=5 ><br><br>
<input type="submit" name="submit" value="Preview">
</form>
</body>
</html>

Preview.jsp

<%@page language="java" import="java.io.* ,java.lang.*,java.sql.*,java.util.*,java.text.*"%>


<HTML>
<HEAD>
<TITLE> Preview </TITLE>

</HEAD>

<BODY bgcolor="#D0D0D0">
<p align=center><font size=5 color=Green>Preview</font></p>
<%! String[] news; %>

<%

String title=request.getParameter("Title");
String f=request.getParameter("img");
String dt=request.getParameter("day");
news = request.getParameterValues("NP");

String mth=request.getParameter("Month");
String y=request.getParameter("Year");
String ndays=request.getParameter("numDays");
String da=request.getParameter("DraftAd");
String count=request.getParameter("Count");
String st=request.getParameter("State");
String ct=request.getParameter("City");
String mc=request.getParameter("mainCat");
String sc=request.getParameter("subCat");
String email=request.getParameter("Email");
String pno=request.getParameter("PhoneNo");
String Size=request.getParameter("size");
String Color=request.getParameter("COLBW");
String pages=request.getParameter("Page");
int cost=Integer.parseInt(request.getParameter("Total"));
%>

<marquee behaviour=alternate direction=right ><hr color=green></marquee>
<div id="Preview" style="padding-right:400px;padding-left:200px;padding-top:4px;padding-bottom:4px; text-align:justify;">

<%

out.println("Title: " +title+"<br>");
out.println("<img src='"+f+"' height=150 width=150 /></img><br><br>");
if (news != null)
{

out.println("NewsPaper :");
for (int i = 0; i < news.length; i++)
{
if(i>0)
out.println(",");
out.println(news[i]);
}
}
out.println("<br>Text :"+da+"<br>");
out.println("State :"+st+"<br>");
out.println("City :"+ct+"<br>");
out.println("MainCategory :"+mc+"<br>");
out.println("SubCategory :"+sc+"<br>");
out.println("Email :"+email+"<br>");
out.println("PhoneNo :"+pno+"<br>");
out.println("Start Date : "+dt+"-"+mth+"-"+y+"<br>");
String DATE_FORMAT = "dd-MM-yyyy";
SimpleDateFormat sdf =new java.text.SimpleDateFormat(DATE_FORMAT);
Calendar c1 = Calendar.getInstance();
c1.set(Integer.parseInt(y),Integer.parseInt( mth)-1 ,Integer.parseInt( dt));
c1.add(Calendar.DATE,Integer.parseInt(ndays));
System.out.println( sdf.format(c1.getTime()));
out.println("End Date : "+sdf.format(c1.getTime())+"<br>");
out.println("Words : "+count+"<br>");
out.println("Size :"+Size+"<br>");
out.println("ColorBW :"+Color+"<br>");
out.println("NewsPaper Page :"+pages+"<br>");
out.println(" Total Cost :"+cost+"<br>");

%>
</div>
<marquee behaviour=alternate direction=left><hr color=green></marquee>
<p align=center>

<form name="form" action="saves.jsp">
<input type="submit" name="submit" value="Save" >

<input type="hidden" name="st" value="<%=st%>">
<input type="hidden" name="ci" value="<%=ct%>">
<input type="hidden" name="main" value="<%=mc%>">
<input type="hidden" name="sub" value="<%=sc%>">
<input type="hidden" name="title" value="<%=title%>">
<input type="hidden" name="ad" value="<%=da%>">
<input type="hidden" name="cnt" value="<%=count%>">
<input type="hidden" name="filename" value="<%=f%>">
<input type="hidden" name="email" value="<%=email%>">
<input type="hidden" name="pno" value="<%=pno%>">

<input type="hidden" name="np" value="<%=news%>">
<input type="hidden" name="day" value="<%=dt%>">
<input type="hidden" name="mon" value="<%=mth%>">
<input type="hidden" name="year" value="<%=y%>">
<input type="hidden" name="days" value="<%=ndays%>">
<input type="hidden" name="sizes" value="<%=Size%>">
<input type="hidden" name="colorbw" value="<%=Color%>">
<input type="hidden" name="pg" value="<%=pages%>">
<input type="hidden" name="amt" value="<%=cost%>">

</form>
</BODY>
</HTML>

saves.jsp

<%@page import="java.sql.*"%>
<%@page import="java.io.*"%>
<html>
<head>
<title>Save</title>

</head>
<body bgcolor="lightblue">
<marquee behavior="alternate" scrollamount=5 scrolldelay=10><h1><font size=4 face="Stroustroup" color="#993355">Advertisement Management System</h1></font></marquee><br>
<%

String st=request.getParameter("st");
String ct=request.getParameter("ci");
String main=request.getParameter("main");
String sub=request.getParameter("sub");
String title=request.getParameter("title");
String da=request.getParameter("ad");
String count=request.getParameter("cnt");
String f=request.getParameter("filename");
String email=request.getParameter("email");
String pno=request.getParameter("pno");
String newsp=request.getParameter("np");
String dt=request.getParameter("day");
String mth=request.getParameter("mon");
String y=request.getParameter("year");
String days=request.getParameter("days");
String size=request.getParameter("sizes");
String colors=request.getParameter("colorbw");
String pages=request.getParameter("pg");
String totalcost=request.getParameter("amt");

File file=new File(f);
FileInputStream in=new FileInputStream(file);
System.out.println(dt+" "+mth+" "+y);

Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con = DriverManager.getConnection("jdbc:odbc:Advdsn");
PreparedStatement ps = con.prepareStatement("INSERT INTO PlaceAd(State,City,MainCategory,SubCategory,Title,DraftAd,Count,image,Email,PhoneNo,Newspaper,Day,Month,Year,Days,Size,Color,Page,Total) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");

ps.setString(1,st);
ps.setString(2,ct);
ps.setString(3,main);
ps.setString(4,sub);
ps.setString(5,title);
ps.setString(6,da);
ps.setInt(7,Integer.parseInt(count));
ps.setBinaryStream(8,in,(int)file.length());
ps.setString(9,email);
ps.setString(10,pno);
ps.setString(11,newsp);
ps.setInt(12,Integer.parseInt(dt));
ps.setInt(13,Integer.parseInt(mth));
ps.setInt(14,Integer.parseInt(y));
ps.setInt(15,Integer.parseInt(days));
ps.setString(16,size);
ps.setString(17,colors);
ps.setString(18,pages);
ps.setInt(19,Integer.parseInt(totalcost));


int x=ps.executeUpdate();
if(x>0)
out.println("Data is saved successfully"+"<br>");
else
response.sendRedirect("PlaceAd.jsp");
ps.close();

%>

<form name="form" action="http://localhost:8080/ProjectAd/Payment.jsp">
<input type="hidden" name="tot" value="<%=totalcost%>">
<input type="submit" name="submit" value="Send" >

</form>
</body>
</html>

Database field are :-

State
City
MainCategory
SubCategory
Title
DraftAd
Count
image
Email
PhoneNo
Newspaper
Date
Month
Year
Days
Size
Color
Page
Total

Please Reply me thank you sir.
View Answers

February 16, 2010 at 3:10 PM

Hi Friend,

Create another database field 'imagename' before 'image' field and do modifications in saves.jsp:

<%@page import="java.sql.*"%>
<%@page import="java.io.*"%>
<%
String st=request.getParameter("st");
String ct=request.getParameter("ci");
String main=request.getParameter("main");
String sub=request.getParameter("sub");
String title=request.getParameter("title");
String da=request.getParameter("ad");
String count=request.getParameter("cnt");
String f=request.getParameter("filename");
String email=request.getParameter("email");
String pno=request.getParameter("pno");
String np=request.getParameter("np");
String dt=request.getParameter("day");
String mth=request.getParameter("mon");
String y=request.getParameter("year");
String days=request.getParameter("days");
File file=new File(f);
FileInputStream in=new FileInputStream(file);
System.out.println(dt+" "+mth+" "+y);
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con = DriverManager.getConnection("jdbc:odbc:access");
PreparedStatement ps = con.prepareStatement("INSERT INTO PlaceAd(State,City,MainCategory,SubCategory,Title,DraftAd,Count,imagename,Image,Email,PhoneNo,Newspaper,day,Month,Year,Days) VALUES(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
ps.setString(1,st);
ps.setString(2,ct);
ps.setString(3,main);
ps.setString(4,sub);
ps.setString(5,title);
ps.setString(6,da);
ps.setInt(7,Integer.parseInt(count));
ps.setString(8,file.getName());
ps.setBinaryStream(9,in,(int)file.length());
ps.setString(10,email);
ps.setInt(11,Integer.parseInt(pno));
ps.setString(12,np);
ps.setInt(13,Integer.parseInt(dt));
ps.setInt(14,Integer.parseInt(mth));
ps.setInt(15,Integer.parseInt(y));
ps.setInt(16,Integer.parseInt(days));
ps.execute();
ps.close();
out.println("Data is saved successfully");

%>
<a href="http://localhost:8080/examples/jsp/Payment.jsp">Payment</a>;

Thanks

February 16, 2010 at 3:22 PM

Hi Friend,

One more thing, the field 'imagename' should be of text type.

Thanks









Related Tutorials/Questions & Answers:
sql
difference between sql and oracle  what is the difference between sql and oracle
sql
sql  how to get first row in sql with using where condition in sql? how to get last row in sql with using where condition in sql
Advertisements
sql
sql  I want interview sql questions   Please visit the following link: SQL Tutorials
Sql
Sql  how to find maximum of a101,a102,a103 from a table in sql
SQL
SQL  hii What is sql?   hello,ADS_TO_REPLACE_1 SQL, which stands for Structured Query Language, is a special-purpose language used to define, access, and manipulate data. SQL is non procedural, meaning
sql
sql  returning value from a store procedure in sql with example   Please visit the following links: http://www.roseindia.net/mysql/mysql5/stored-procedures-and-functions.shtml http://www.roseindia.net/sql/create
SQL
SQL  In my computer i have microsoft sql 2008.how can i set that in the cmd.i want to use that in cmd.what is the default username and password
SQl
SQl  . Given two tables: table1(player, groundname, numcenturies); table2(ground_name, country); Write and SQL query for the following: " Select all the players from table1 who has
SQL
SQL   1)How to Store 1000 records in Oracle object. 2)Write a query for calculate highest, 3rd Highest & 10th highest salary from emp teble. 3)What is Sequence. 4)How to use rowid in Sql. 5)What is Views. 6)How
SQL
SQL  how to get ( 15 march 2011) and (15/03/2011) output using SQL   Use the following queries to get the data from database in the given format. For (15 march 2011) format: SELECT DATE_FORMAT(dob, '%d %M %Y') FROM
SQL
SQL  how to get ( 15 march 2011) and (15/03/2011) output using SQL   Use the following queries to get the data from database in the given format. For (15 march 2011) format: SELECT DATE_FORMAT(dob, '%d %M %Y') FROM
SQL
SQL Trigger query  Why we use the Trigger and what it's uses?   A database trigger is procedural code that is automatically executed..., user events, and SQL statements to subscribing applications 10)Restrict DML
SQL
tables EMP, and DEPT, the structure for which are given above. Write SQL queries
SQL
events, user events, and SQL statements to subscribing applications 10)Restrict DML
SQL
, user events, and SQL statements to subscribing applications 10)Restrict DML
SQL
events, and SQL statements to subscribing applications 10)Restrict DML
sql - SQL
order by SQL Query  What is order by in SQL and when this query is used in SQL?Thanks!  Hi,In case of mysql you can user following query.Select salary from salary_table order by salary desc limit 3,1Thanks
sql - SQL
want query? 4.what is the diffrence between sql and plsql?  Hi Friend... HAVING n>1; Difference between SQL and PL/SQL: SQL is a structured query...(select,insert,update etc.), manipulate objects(DDL) and data(DML). PL/SQL
sql - SQL
sql  write a dyamic sql program to display the name of a employee whose salary is <5000  Hi Friend, Use the following query... the following link: http://www.roseindia.net/sql/ Thanks
SQL - SQL
SQL  Jus c da case we hve certain images in some folder or some area in sql can we create trigger or procedure so dat in front like in asp page while clicking image it will be showed in page ...... ...I mean writing code for each
SQL - SQL
SQL  How to combine 'LIKE' and 'IN' operators in sql query?   select name from tab1 where name like 'R%' AND city in('bangalore','mumbai'); Table Name: tab1 FieldName ===================== | name | city
sql - SQL
sql functions with examples  I need sql functions with examples to learn fast.  Hi friend,<%@ page language="java" import...("SQL statement is not executed!"); } } catch (Exception e
sql server - SQL
sql server  what is SQL server? & what is oracle? are they same
sql server - SQL
sql server  How many no of tables can be joined in same sql server
An SQL Locator.
An SQL Locator.  What is an SQL Locator
sql component
sql component  is sql package is the component of jdbc
SQL help - SQL
SQL help  Hi Deepak, Can u pls tell me what is the difference between PL/SQL and MYSQL? Is there any difference in generating the code
SQL JOINS - SQL
SQL JOINS  Hom many Joins In Sql?plz explian all those things?  Hi Friend, Please visit the following link: http://www.roseindia.net/sql/sqljoin/index.shtml Hope that it will be helpful for you. Thanks
learn sql - SQL
learn sql  how to learn sql......idont know anything about programming knowledge  Hi Friend, Please visit the following link: http://www.roseindia.net/sql/ Thanks
sql 2000 - SQL
sql 2000  why binary data when inserted into the sql column of data type image or binary is stored in the form of hexadecimal nos. instead of the name of the file inserted????? Thanx for ur response in advance
auto sql script - SQL
auto sql script  Is there a way of generating inserts scripts using the table structure for oracle database
sql quries
sql quries  i want basic sql quries please provide
SQL injunctions - SQL
SQL injunctions  Could you please tell me how to handle the sql injunctions?  Hi friend, SQL injection is a technique that exploits.... Prevention against SQL injection, User input must not directly be embedded in SQL
Sql Server - SQL
sql server trigger example  Can any one tell me the live example of triggers in SQL Server?   if u click pistal trigger ,it auotmatically shoot bullet it's like newtons 3rd law (every action s having an equal reaction
SQL injection
SQL injection  hii, What's an SQL injection?   HII,ADS_TO_REPLACE_1 SQL Injection is when form data contains an SQL escape sequence and injects a new SQL query to be run
Sql row retrieve - SQL
Sql row retrieve  Sir What are the sql statements so that I can retrieve rows from a table by specifying the row numbers such as row no.5 to 10...; Sir What are the sql statements so that I can retrieve rows from a table
SQL Plus
SQL Plus  What is SQL Plus?   Hi, Here is the answer,ADS_TO_REPLACE_1 SQL*PLUS is a command line tool where as SQL and PL/SQL language interface and reporting tool. Its a command line tool that allows user to type SQL
SQL
SQL       SQL SQL is an English like language consisting of commands to store, retrieve, maintain & regulate access to your database. SQL*Plus SQL*Plus
SQL Error - SQL
SQL Error  Invalid character value for cast specification on column number 5 (Designation) Whats this error about this if the field i specified in programming error. ie DB fields in above question
SQL Server
SQL Server  Hii, What is SQL Server ?   hello,ADS_TO_REPLACE_1 SQL Server is a DBMS system provided by Microsoft
insertion in SQL - SQL
in the database because of single code in the name. dbase is MS-SQL emp.name data type... as I know string parameter in SQL is denoted as 'john' . I think thats why... str = "John's"; str = str.replace("'","\\'"); String sql
Java and SQL - SQL
in getting a data to SQL. my problem is on how to come up with a pop up alert message in the user interface where in the message will be coming from the SQL table. the message was in the SQL table and i want to get that message
SQL Query - SQL
SQL Query  Hi I would like to know how to create a SQL query which would copy values from a field which contains multiple values to an existing table. I created table 2 and defined the fields.I tried different types of insert
Sql Interview questions? - SQL
Sql Interview questions?  Define join?when will use join? define Inner join? give the example? and when will use inner join? define outer join...://www.roseindia.net/sql/sqljoin/index.shtml Hope that it will be helpful for you
insertion in SQL - SQL
insertion in SQL  Hi! Everybody... i have a problem with sql insertion. When i am inserting values through command i.e. insert into employee... on Insert Query visit to : http://www.roseindia.net/sql/insert.shtml Thanks
sql - JDBC
key constraints in SQL server  Does SQL have a FOREIGN KEY constraints in a Table
sql - JDBC
SQL joins queries   Hi, can anyone give me the couple of SQL joins queries with examples
sql and .net
sql and .net  I want get coding of connecting data base sql server 2000 to .net please help
Sql to excel
Sql to excel  How to convert a Sql Data into excel Doc with Using Netbeans
Sql question
Sql question  How to display duplicate values in Sql?   Hi Friend, Please visit the following link: http://www.roseindia.net/sql/mysql-example/mysql-finding-duplicate-records.shtml Thanks

Ads