Query of queries on 2 data sources
I'm doing a query of queries on 2 different data sources. I run a gaming site and have a 2 programs that are used for tracking. One is written in php, by someone else, following members point State. The other, I wrote it in CF, allows members to set priorities in Treasury. Both are independent on my server. What I'm trying to do is set up so that the program I wrote to FC shows the number of points, each Member has. I know how interrogate separate tables, but how do I combine them? In addition, how can I set up so that it only shows members that match. that is, I want to assure you that if John Smith has 100 points, the query will show John Smith 100 points on my table. Here is what the query looks like I did. As you can see, I'm confused about and WHERE statements. I played with him last night and could not make it work. Thank you.You can try the same correction/idea of what I posted in thread http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid=1&catid=7
Copied/Pasted from this thread:
You can read through the first query and add content to a query to temp attributing some kind of field and then read through the second query and add same temp with a kind of field to the query. Then do a query of this temp query.
Tags: ColdFusion
Similar Questions
-
A single query, two data sources
Is it possible to run a query on two distinct datasources? I would compare the data of two databases MS Access separate.
Thank you.You will not be able to combine two data sources in a cfquery, so one way might be for you for each query data source, and then compare the two results using a Q-Q.
Phil
-
Query a data source using this format - {call displayLocation()}?
I inherited a CF app and surprisingly I never met calling a function, or a procedure stored like this before. I'm unable to locate the data source, I'm guessing that this is perhaps an Access db?
< cfquery datasource = "MyDSN" name = "$myvariable" >
{call displayLocation()}
< / cfquery >
Well, the numbers. Half an hour later, I find what I'm looking for. It's just an another MSSQL Server SP.
-
Breaking using a concatenated data Source
Greetings,
I'm breaking a report using a concatenated data source. I have a SQL query break implemented that works very well, but I'm not sure how to handle the option "Split." I have a data model that extracts data from multiple queries, like this:
DETAILS_A
Select * from table_a
where payee_id in (: p_payee_id)
DETAILS_B
Select * from table_b
where payee_id in (: p_payee_id)
So, if I choose "Split by" Details_A_Row/Payee_ID, then the Details_A data are distributed properly, but reports that generate don't split the Details_B information correctly. I find myself with reports where a beneficiary has information for another beneficiary of the data source Details_B. How can I specify that the report should also split/filter the news of Details_B?
To put it another way, what I like to do is really going through a list of parameters (paid IDs in this example) and generate a report for each parameter. Is the most effective way to do it?
Research forums, it seems that I might be able to achieve using data models as my model of data instead of SQL queries. I'm on the right track with that? If so, you guys have all the useful links on how to create data models?
I use Publisher version 10.1.3.4 BI
Any help is appreciated!
MartinHere is a good starting point:
http://download.Oracle.com/docs/CD/E12844_01/doc/BIP.1013/e12187/T421739T434255.htm
See you soon
Jorge
-
I use the same data source to create a query of queries, but one of my questions is not recognized. The codes and messages are the following:
You do not use the datasource with a query of query property
tag. When you do a query of query you are dealing with record sets
memory. Delete the "datasource" setting in the thirdtag. -
Hi all
I work in a retail environment in retail and we build reports for stores. There are several reports and that they receive the same reports. We use the BEEP company with breaking function and it works fine.
The problem is that there are too many reports and we would like to consolidate all of the reports from the same store in the same PDF. We use the function of multiple data source and managed to concatenate all the comprehensive reports.
Using this model, and the new report, we cannot make breaking functionality works correctly: the burst report contain all components of report required.
For example, I have 2 questions A and B producing each of the reports for 3 stores: 2, 4, and 5. Without rupture, the result is such that it is:
Query A - store 2
Query A - store 4
Query A - store 5
Query B - store 2
Query B - store 4
Query B - store 5
With the outbreak in a file using the store number, I get the following:
File 1 - store 2 - query A
File 2 - store 4 - query A
File 3 - Store 5 - query A
+ Store 2 - question B
+ Record 4 - B query
+ Store 5 - question B
I wish I had the following result:
File 1 - store 2 - query A
+ Store 2 - question B
File 2 - store 4 - query A
+ Record 4 - B query
File 3 - Store 5 - query A
+ Store 5 - question B
The main question is: is it possible using Enterprise Pub BI? We are using the 10.1.3.3.2 version
If this is the case, can you provide me with help on how to configure either / or queries and the model to accomplish this task?
I create an SR and Support of Oracle is not an answser and suggested someone in the Forum could help.
Thanks in advance,
MinhI wish I had the following result:
1-2-query A file + Store 2 Store - query B
File 2 - store 4 - query A + Store 4 - query B
File 3 - Store 5 - query A + Store 5 - query Bthe level of break must be give to
1-2-query A file + Store 2 Store - query Bthe tag in the xml file must be broken down by common to these three rows.
Since the data comes from the application of different, and data won't be under the single label.
You can't burst using the concatenated data source.But you can do by using datatemplate and bind the request and get data for each file in a single query.
Select distinct store_name in all stores
Select * from query1 where to store the name =: store_name = 1st request
Select * from query2 where to store the name =: store_name = 2nd request
set the datastructure as you wish,
the XML will contain something like that
-to store 2
-to store 3
-for the store 4
-to store 5
Now you can it burst at the store level.
-
SSRS for lack of outer join with the Oracle data source
It seems to be a problem with the Oracle driver used in the Reporting SERVICES query designer.
When you use an Oracle data source, if I create an outer join in the graphic designer, it automatically inserts '{OJ' before the join and '} ' after her. This is an incorrect syntax for Oracle and refuses to start. The curly braces and the JO editable in designer text, but if I go back to the graphic designer and immediately to reintegrate them.
Only, this has started to happen a year or two ago - before that it worked, but with the old (+) syntax.
Can it not be healed? It makes things very difficult.
-Geoff
Hi Geoff,
Thanks for posting in the Microsoft Community.
However, the question you posted would be better suited in the Forums of the Oracle Support; We recommend that you post your query in Oracle Support Forums to get help:
If you have any other questions or you need Windows guru, do not hesitate to post your questions and we will be happy to help you.
-
A data source using an app does not not to start
I'm adopting the tutorial: https://developer.blackberry.com/cascades/documentation/device_platform/data_access/using_data_sourc... at my request. The only difference is that my app is based on the tabs. Following however to add lines in my file qml, makes the application crashes the gray screen with BB10 logo.
Tab { title: "edit list" imageSource: "asset:///images/note.png" content: Page { titleBar: TitleBar { title: "editing list: " + workingOnList visibility: ChromeVisibility.Visible } Container { id: view ListView { layout: StackListLayout { } preferredWidth: 640.0 // Associate the list view with the data model that's defined in the // attachedObjects list dataModel: dataModel listItemComponents: [ ListItemComponent { type: "item" // Use a standard list item to display the data in the model StandardListItem { title: ListItemData.category_name } } // end of ListItemComponent ] } attachedObjects: [ GroupDataModel { id: dataModel }, DataSource { id: dataSource // Load the data from an SQL database, based on a specific query source: "database.db" query: "select * from categories" onDataLoaded: { // After the data is loaded, insert it into the data model dataModel.insertList(data); } } // end of DataSource ] onCreationCompleted: { // After the root Page is created, direct the data source to start // loading data dataSource.load(); } } } }
The only differences are: code is pasted in the {} instead of {Page} tab, and of course, the name of the database, the columns are changed.
I added bb.data 1.0 import statement in the file .qml, the .pro file was also changed according to the tutorial. Path to the database file is correct.
You have an idea, why this is happening?
Another issue related to the data source:
my main.qml file:
Page { id: mainScreen titleBar: TitleBar { title: "your lists" visibility: ChromeVisibility.Visible } Container { ListView { id: allListsView objectName: "allLists" layout: StackListLayout { headerMode: ListHeaderMode.Sticky } dataModel: allListsModel listItemComponents: [ ListItemComponent { type: "item" StandardListItem { title: ListItemData.list_name } }, ListItemComponent { type: "header" Header { title: ListItemData } } ] onTriggered: { select(indexPath); var page = listPage.createObject(); nav.push(page); } } attachedObjects: [ ComponentDefinition { id: listPage source: "listPreview.qml" }, GroupDataModel { id: allListsModel grouping: ItemGrouping.ByFirstChar sortingKeys: ["list_name"] }, DataSource { id: allListsSource source: "database.db" query: "select * from lists" onDataLoaded: { allListsModel.insertList(data); } } ] onCreationCompleted: { allListsSource.load(); } }
New screen grows without any problem after clicking on list items. But when I add the following lines to listPreview.qml, application stucks selection list item and nothing happens.
Page { content: ListView { id: myListView dataModel: dataModel listItemComponents: [ ListItemComponent { type: "item" StandardListItem { title: ListItemData.article_name } } ] } attachedObjects: [ GroupDataModel { id: dataModel }, DataSource { id: dataSource source: "database.db" query: "select * from articles" onDataLoaded: { dataModel.insertList(data); } } ] onCreationCompleted: { dataSource.load(); } }
It looks like I can not query the DB for the second time commenting on the DataSource {...} of listPreview.qml pushed the new app screen without any problems.
EDIT:
a simple solution: I forgot to add the statement import bb.data 1.0 in listPreview.qml
-
Hello
I'm almost done to convert my application to use XML to JSON; the last thing I need to reconfigure is my field of research (which is looking the listView data source).
In XML, I would fix the query:
query: "/root/continent"
looking for this file:
XML
Brazil vs Croatia Thursday 12 June 2014 17:00PM (Local Time) Arena de Sao Paulo So now, I have converted more of JSON and instead use the title of listItem, I use fixtureInfo just as they were both providing the same information.
JSON
[ { "type":"item", "id":"1", "dateNumber":"12/06/2014", "fixtureInfo":"Brazil vs Croatia", "dateInfo":"Thursday 12 June 2014", "timeInfo":"17:00PM (Local Time)", "timestamp":"1402603200000", "stadiumInfo":"Arena de Sao Paulo" } ]
Data source:
DataSource { id: dataSource1 property string sQuery: "" onSQueryChanged: { dataModel1.clear() load() } source: "asset:///JSON/Fixtures.json" type: DataSourceType.Json remote: false onDataLoaded: { //create a temporary array tohold the data var tempdata = new Array(); for (var i = 0; i < data.length; i ++) { tempdata[i] = data[i] //this is where we handle the search query if (sQuery == "") { //if no query is made, we load all the data dataModel1.insert(tempdata[i]) } else { //if the query matches any part of the country TITLE, we insert that into the list //we use a regExp to compare the search query to the COUNTRY TITLE (case insenstive) if (data[i].listItem.title.search(new RegExp(sQuery, "i")) != -1) { dataModel1.insert(tempdata[i]) //Otherwise, we do nothingand donot insert the item } } } // this if statement below does the same as above,but handles the output if there is only one search result if (tempdata[0] == undefined) { tempdata = data if (sQuery == "") { dataModel1.insert(tempdata) } else { if (data.listItem.title.search(new RegExp(sQuery, "i")) != -1) { dataModel1.insert(tempdata) } } } } onError: { console.log(errorMessage) } }
Therefore, what set that the query - for my data source - so that it will pick up the JSON data as before with XML?
Thanks in advance.
Like many I know THAT JSON does not use a query. Check out these https://developer.blackberry.com/native/documentation/cascades/device_platform/data_access/working_w... https://developer.BlackBerry.com/native/reference/Cascades/bb__data__jsondataaccess.html
-
Fill the drop-down list in the SQL data source
I have a data source that retrieves data from an sqlite database. How do I pass two areas of this query to a drop-down list on the page. I want to create a drop down list with the value and the text of this data source
Hello
To extract the values you need to wait for onDataLoaded. "data" parameter is a list of cards.
An example of code for data access :
http://supportforums.BlackBerry.com/T5/Cascades-development/SQLite-count-query/m-p/2477699#M27180
To add an option to the menu drop-down:
attachedObjects: [ ComponentDefinition { id: optionFactory Option { } } ] ... to add an option: var newOption = optionFactory.createObject() newOption.text = 'Text to add' // or a variable fetched from data source//newOption.otherfields = ... dropdownId.add(newOption);
-
Multiple queries in a data model - Performance?
Hi experts,
I created a data model and defined queries 7 (isolated; not connected together). I want to create 7 reports based on queries 7 (for example query1 used in Report1, query2 used into Report2, etc.).
The consolidation of 7 queries in a data model affect performance? How the BEEP collects data - is only the query used processed, or each time the entire data model?
Thanks in advance!
Hello
According to the data that you want to use in your report.
In a report, you can use data from more than queries.
We recommend that you create 1 data model for each report, for a good performance with all applications you need.
7 queries fetch data slower than 1 query in your data model.
Kind regards
Liviu
-
Dear,
How can I create a new data source (JNDI) for DB external.
I want to be able to query the DB using JDBC, but I want the data to be managed by nenucleus source.
You can create a component like this:
MyDataSource.properties
$class = atg.service.jdbc.FakeXADataSource
User = user
password = password
URL=JDBC:Oracle:thin:@localhost:1521:XE
Driver = Oracle.JDBC.Driver.OracleDriver
After that, do the injection in the other component:
OtherComponent.properties
genericDS = / your/component/MyDataSource
In Java, to get the connection:
OtherComponent.java
Private XADataSource genericDS;
getters and setters...
Take a look also at:
Configuration of Data Sources ATG for importing data
I hope it helps.
-
Nested queries in Apex/BEEP Source?
With the help of Apex 4.0.2.00.07, I have a master report / detail required that has a rather long header/footer and then lots of detail rows. The ideal ratio would eventually something like the following:
Paragraphs in header information
Line 1
....
Line 100
Info from footer paragraph
Is it possible for the Apex report queries to generate the XML to nest queries? I know that I can throw it all in a single record by joining tables, but then I have to generate all the header information for each line instead of once for each master record. I know that BEEP can handle it because I can do it for EBS by defining relationships of the query in the definition of data, but I can't seem to find a way to do it in the Apex report query. I've seen several comments on this issue, but no definitive answer. If anyone can help, I'd appreciate it.
Jessica,
You can not. If you decide to put all the data in a single line, you can build your model to break in the header data. The other option is to generate the report in the Pub BI and then call the report using webservice api bi pub.
Introduction to the Web Services BI Publisher - 11g Release 1 (11.1.1)
-
Access denied on a data source
A big problem, I can't use my new datasource CF.
I use to declare datasource on a 64-bit C F9, Windows Server 2008 environment CF 64 bit.
I have about 80 datasources declared (mdb Access files).
I use the same procedure to create my datasource.
create the source data ODBC32.
Then create the CF data source bound to the created ODBC data source.
As I always do.
When I check the data source in the CF admin, he said OK. everything looks good
And when I do a query to the data source,
I have this message:
Security: The requested model denied access to allergan_prof_sante.
This is the inner exception message: access denied (coldfusion.sql.DataSourcePermission allergan_prof_sante) I tried to create another source of data.
Same behavior. OK in CF admin
And "access denied" when you make a query.
So now, any data created source not available.
I don't change anything on Windows Server
The only change is my client PC which ftp the file mdb.
It of Vista and now windows 7.
Any emergency assistance is welcome. I can't use more new source of data.
All the old datasource are working properly.
I looked at the properties of mdb files, old and new, they have the same.
Thanks for help.
Thank you all,
I checked the DSN name in odbc32, CFadmin, code, I put the same everywhere.
Same behavior. (and always successful in CFadmin)
BUT the BIG: security sandbox problem, really very good, full of grace...
Then, when you create a new data source, it is now automatically is datasource "disabled".
I just have to turn them back on.
Why this changed? God only knows?
Or maybe "security sandbox was not checked some time ago, and I did it,
do not think that this new data source will be disabled.
Thank you very much again, I was so lost and down.
Stone.
-
BI Publisher for OBIEE data sources
I know that BI Publisher can be part of an OBIEE Dashboard using a query OBIEE answers as the source data for the BI Publisher report. My question is if a BI Publisher report can have one data source other than an OBIEE answers such as a custom SQL query and still be part of an OBIEE dashboard? If possible, no matter what version of OBIEE and BI Publisher is used?
Thanks for information of nay you can provide on this subject.
BarryHello
data source other than a request for responses OBI can be included in a dashboard OBIEE.
Using the dashboard objects, we can call the BIpublisher report in the dashboard.Thank you
Ananth
Maybe you are looking for
-
Question about video drivers Satellite P100-257
Hello.Question about video driver. Version 14.25... Works (tells... 945 GM chipset); 14.27--works but with ocassional problems (tells... 945GM/GU); version 14,29... (said 945GM/GU) - does not work at all - black screen, but you can hear sounds which
-
VerticalFieldManager no scroll bar
In my application, I have two different cases where my VerticalFieldManager scrolls, but it will not show scrollbars. Here is the code I have them during initialization. private VerticalFieldManager manager = new VerticalFieldManager(VerticalFieldMan
-
Hello I develop thrid party application for Blackberry. I use the API paid the BlackBerry in my application. I read about the process and costs of code signing. Currently, I'm testing my application on the Simulator. My query is- Once I finished the
-
It is not driven blackBerry Smartphones Blackberry Bold 9780
My phone was constantly display an error message and sometimes the screen turns white. He finally stopped and goes to market any more. It shows several times have a light red as if it lights. How can I hv it fixed?
-
Pre-installed Windows 8 does not properly.
Hello I have a HP Elite 7500 desktop PC and it has a pre-installed Windows 8 Pro 64-bit. When I tried to set up for his first start, I have unfortunately to stop the process and when I restart the pc it says that you need to re - install windows. but