I'm create a list item via ASP.Net to be published automatically on Sharepoint. However, I cannot find how to define the content type via the CAML query.
Hi,
i am having an form for uploading an excel file like
<form enctype="multipart/form-data" action="http://localhost/joomla/Joomla_1.5.7/index.php?option=com_jumi&fileid=7" method="POST">
Please choose a file: <input name="file" type="file" id="file" /><br />
<input type="submit" value="Upload" />
</form>
And in the FIle http://localhost/joomla/Joomla_1.5.7/index.php?option=com_jumi&fileid=7
i have retrived the uploaded file contents by
<?php echo "Name". $_FILES['file']['name'] . "<br />";
echo "Type: " . $_FILES["file"]["type"] . "<br />";
echo "Size: " . ($_FILES["file"]["size"] / 1024) . " Kb<br />";
echo "Stored in: " . $_FILES["file"]["tmp_name"] . "<br />";
$string = file_get_contents( $_FILES["file"]["tmp_name"] );
foreach ( explode( "\n", $string ) as $userString )
{
$userString = trim( $userString );
echo $userString;
$array = explode( ';', $userString );
$userdata = array
( 'cf_id'=>trim( $array[0] ),
'text_0'=>trim( $array[1] ),
'text_1'=>trim( $array[2] ),
'text_2'=>trim( $array[3] ),
'text_3'=>trim($array[4]),
'text_6'=>trim($array[5]),
'text_7'=>trim($array[6]),
'text_9'=>trim($array[7]),
'text_12'=>trim($array[8]));
global $db;
$db =& JFactory::getDBO();
$query = 'INSERT INTO #__chronoforms_UploadAuthor VALUES ("'.$userdata['cf_id'].'","'.$userdata['text_0'].'","'.$userdata['text_1'].'","'.$userdata['text_2'].'","'.$userdata['text_3'].'","'.$userdata['text_6'].'","'.$userdata['text_7'].'","'.$userdata['text_9'].'")';
$db->Execute($query);
echo "<br>";
}
i am trying to insert the contents into the table #__chronoforms_UploadAuthor in Joomla database . it doent shows any error but it is not inserted into the database..
Please help me.. Y the contents are not inserted into the database...And how to make it inserted into the database..
hi how can i use more than one 'between' clause in mysql query ? like if i want to select students having height between 20 and 25 and weight between 50 and 70..
thanks in advance
tismon
When you query the ALL_TAB_COLS view on Oracle 9i, it lists columns marked as UNUSED as well as the 'active' table columns. There doesn't seem to be a field that explicitly says whether a column is UNUSED, or any view I can join to that lists the unused columns in a table. How can I easily find out which are the unused columns, so I can filter them out of ALL_TAB_COLS?
currently I have this setup in our simple-hosts.conf:
url.rewrite-once = (
".*.(js|ico|gif|jpg|png|css|php|htm)(?.*)?$" = "$0",
"/slapi" = "/slapi/index.php"
)
Works great, except the above fails when I have a dot in the query string:
?url=http://google.com
My regexpy is not 1337
Hello,
I have simple situation (like on the image link text) and simple SQL query
SELECT M.Name,
A.Name,
B.Name
FROM Master M LEFT JOIN DetailA A
ON M.DescA = A.Id LEFT JOIN DetailB B
ON M.DescB = B.Id
How to achive the same effect in nHibernate using CriteriaAPI ?
How to transfer json data to html with php?
$url="http://api.nytimes.com/svc/search/v1/article?format=json&query=usa&rank=newest&api-key=mykey"
when I type the url in browser, it return
{"offset" : "0" , "results" : [{"body" : "A guide to cultural and recreational goings-on in and around the Hudson Valley. ...}]}
how to put the json body data into html? I mean like this echo '<div class="body"></div>';
I'm querying a view and filtering the results with a column named status. I'd like to query it so I can search for rows with different status, by using the IN operator as I'd do in SQL.
As so:
SELECT * FROM VIEW WHERE Status in ('....', '.....')
How can I achieve this?
Language Integrated Query. Now I know that the acronyms are. I have seen C# examples, but can't really understand them. Can I use them with PHP? Can I use it along with ORM? Has any PHP MVC framework has this?
I can use something like:
cvs.exe rdiff -D2010-03-23 -D2010-03-24 -s "ProjectName"
to get the changes which occurred on the 23rd.
But I want to get the changes that were checked in on the 23rd on a specified branch - and if I add in a -v branchv1-0-0-0 into that it tells me I can't have more than two dates/revisions in one query.
Any suggestions?
I have a page and clicked on the button there it will open a new page containing some text boxes, user fill all the text boxes and clicked the button now first page open again and the question is : How can I get the vales of text boxes on the current page using both server-side and client-side
There is a restrictions to use of :
- Cross-paging
- Cookies
- Sessions
- Query strings
Part of the code:
...where se.DateFrom >= pDateFrom && se.DateTo <= pDateTo select se...
Does not work. There is no any error but the To and From days do not get returned.
How do I query "more than or equal to" and "less than or equal to"?
Thanks :)
I have a problem with AND and OR clause in SQL. Here is my query:
SELECT
`act1`.`name`,
`act1`.`surname`,
`act2`.`name`,
`act2`.`surname`,
`act3`.`name`,
`act3`.`surname`
FROM
`videos`,
`actors` AS act1,
`actors` AS act2,
`actors` AS act3
WHERE
`videos`.`ident` = 'somethink'
AND
(
`act1`.`id` = `videos`.`id_actor1`
OR
`act2`.`id` = `videos`.`id_actor2`
OR
`act3`.`id` = `videos`.`id_actor3`
)
It returns me all variations of {name, surname}, but I want the name and surname of first exactly, second and thirth, if they exist.
Hi i have a yaml file like so
---
data:
- date: "2004-06-11"
description: First description
- date: "2008-01-12"
description: Another descripion
How can i do a "ypath" query similar to xpath for xml ? Something like "get the description where the date is 2004-06-11"
YAML.parse_file('myfile.yml').select('/data/*/date == 2004-06-11')
How do you do it, and if that's possible how can i similarly edit the description by 'ypath' ?
Thanks
I have three tables with a common key field, and I need to join them on this key. Given SQLite doesn't have full outer or right joins, I've used the full outer join without right join technique on Wikipedia with much success.
But I'm curious, how would one use this technique to join three tables by a common key? What are the efficiency impacts of this (the current query takes about ten minutes)?
Thanks!
Why do I get a 400 - bad request error using the following URL? It is encoded using Server.UrlEncode. The actual path query parameter is C:\Development\Chase\Exports\ChaseExport-090312073930.zip
http://localhost:50199/Common/Forms/Export_Stream.aspx%3fpath%3dC%3a%5CDevelopment%5CChase%5CExports%5CChaseExport-090312073930.zip
I have a grouped query, and would like to filter it based on count(*)
Can I do this without a subquery?
This is what I have currently:
select *
from (select ID,
count(*) cnt
from name
group by ID)
where cnt > 1;
How to combine these two sql queries into one?
SELECT DISTINCT * FROM rss WHERE MATCH(content,title) AGAINST ('$filter')
SELECT COUNT(content) FROM rss WHERE MATCH(content,title) AGAINST ('$filters')
And if the result is 0 from the above query
-
SELECT DISTINCT * FROM rss WHERE content LIKE '%$filters%' OR title LIKE '%$filters%';
$filter .= $row['filter'];
$filters = $row['filter'];
$filters may be more than one keyword
When I try to put a value into a DATE field which is invalid, MySQL seems to use 0000-00-00 instead. Is there a way I can do this "check" without updating a DATE field? And to do it from for example PHP?
Like, is there a way I can query the MySQL server and ask "Hey, is this DATE, TIME or DATETIME valid to you?"
Or is there maybe an even better way of doing it?
Lets say there is some code that executes the following SQL query:
set rowcount n
But n is unknown. Is there any way to know what n was? I'm using Sybase.
Hi I am using Crystal Reports 10 to generate my reports. In one of the reports I see that a group header is getting repeated 2 times in the output document while in the design tab I can that it is present only one time. I am having my query as a "Union All" of 2 data sets.
Please advise what could be the cause. Thanks.
If I have a table like this:
pkey age
---- ---
1 8
2 5
3 12
4 12
5 22
I can "group by" to get a count of each age.
select age,count(*) n from tbl group by age;
age n
--- -
5 1
8 1
12 2
22 1
What query can I use to group by age ranges?
age n
----- -
1-10 2
11-20 2
20+ 1
I have an old Access database that is being upgraded to work with Access 2007. The client is complaining that it is slow now. I am looking for ways to optimize it.
There is one subform that is in a particular tab on the form. I have been wondering -- does the subform still update/query even when it is not visible?
If this is configurable --- how?
select @[email protected]('*')
for xml raw,type
Above statement will generate following alert:
Msg 6819, Level 16, State 3, Line 2
The FOR XML clause is not allowed in a ASSIGNMENT statement.