Posts

oracle11g - Visual Studio, SSRS, Oracle sys_context('USERENV', 'OS_USER') -

i using visual studio 2012, oracle 11g , ssrs 2012. i have developed report checks session userid determine if can view report or not against table stored in oracle db. everything works correctly in preview mode visual studio 2012; however, when report deployed ssrs 2012 data not returned, , expected if us. select comp_flag, mbr_mmis_idntfr, last_name, first_name, middle_name, org_code, org_name, org_phone, last_verified_date, rac_start,rac_end, rac_code tpl_chip_mv (comp_flag <> 'n') , (1 =(select count(user_id) expr1 report_auth (user_id = concat('hlan\',upper (sys_context'userenv', 'os_user')))))) why work correctly in visual studio 2012 preview mode , not in ssrs 2012? can work in ssrs? the problem os_user different. when you're running locally in preview mode, account running visual studio own personal account. os_user database sees personal operating system user. when you're deployin...

django - How to setup the initial value in select control? -

i'm trying setting select control on form, not achieving expected results. me, strangest thing working in previous control, same type. this function involved: class proofmspe(crearevidencia): model = vrl02 form_class = vrl02form def get_form(self, form_class): form = super(proofmspe, self).get_form(form_class) form.fields['miembro'].queryset = self.pipol if self.pipol.count() == 1: form.fields['miembro'].widget.initial = [self.pipol[0].id] form.fields['meta'].initial = self.meta form.fields['meta'].widget.attrs['disabled'] = true return form the meta 's control select , got expected behavior, ie automatically selects initial value ( form.fields['meta'].initial = self.meta , inthe next lines, disabled ( form.fields ['meta']. widget.attrs ['disabled'] = true ). output in rendered template: <!-- begin meta--> <div class=...

unix - How do I retrieve the current song name and time left from pianobar using python? -

i'm creating alarm clock gui using tkinter , python on raspberry pi. when alarm goes off want start playing pianobar. can enough, want display name of song on gui, , cannot figure out how current song being played. have tried using pipes "|", , redirecting ">" have gotten nowhere. advice help. you need use event command interface. man page: an example script can found in contrib/ directory of pianobar's source distribution. ~/.config/pianobar: user = <username> password = <password> (although i'd suggest password_command) event_command = ~/.config/pianobar/event_command.py ~/config/event_command.py #!/usr/bin/env python import os import sys os.path import expanduser, join path = os.environ.get('xdg_config_home') if not path: path = expanduser("~/.config") else: path = expanduser(path) fn = join(path, 'pianobar', 'nowplaying') info = sys.stdin.readlines() cmd = sys.argv...

jquery - replace character at certain position inside javascript -

this question has answer here: how replace character @ particular index in javascript? 17 answers if have string inside javascript function like function somefunction(){ var mystr = "12345678911"; var maskedstr = ""; } how can use mystr values * maskedstr contain string like var maskedstr = "1234567*91*"; function somefunction(){ var mystr = "12345678911"; var maskedstr = mystr.replace("9", "*"); }

javascript - PouchDB about 3x slower inserting 4800 documents over websql -

been exploring use of pouch db potentially leverage offline sync instead of doing our own. have cordova app pulls data rest api , saves web sql store. part of around 5k physical locations various stores. timed on cordova app, , download stores & save them, along request project information in 11 seconds. saving of these 5k records documents in pouch db takes 30 seconds. not counting request time. here's do: let db = pouchproxy.getdb(); this.render("loading", { message: "saving locations" }); // stores api let stores = res.stores; let docs = []; // check saved stores, checking ids start store_ db.alldocs({ include_docs: true, startkey: 'store_', endkey: 'store_\uffff' }).then((results) => { // go through saved stores (let row of results.rows) { let doc = row.doc; // number id. _id 'store_idnumfromapi' let id = parsefloat(doc._id.split('store_')[1]); if (isnan(id)) { throw "cannot nan...

java - Iterate a list of objects and compare properties -

i trying iterate list containing helper class objects , compare properties of helper . based on comparison if validation fails,i wanted show error message user. below code snippet. public static void main(string[] args) { map<string, string> errormap = new hashmap<string, string>(); simpledateformat format = new simpledateformat("dd/mm/yyyy"); list<helperdto> helpers = new helpertest().gethelpers(); (helperdto helperdto : helpers) { string helperpkey = helperdto.gethelperpkey(); string employeepkey = helperdto.getemployeepkey(); string helperstart = helperdto.gethelperstart(); string helperend = helperdto.gethelperend(); if (helperstart == null || "".equals(helperstart)) { errormap.put("helperst_" + helperpkey, "helper start required"); } if (helperend == null || "".equals(helperend)) { errormap.p...

installation - visual studio 2013 update 2 taking to long to configur -

Image
i have installed visual studio 2013 version 2 , installation process stuck , not giving me error... help me should do? if installation process stuck wait long time. times happens takes long. or cancel installation process , re-start. there no solution this. there no such problem can solve while installation going on. advice not try thing foolish change system configuration , other application misbehave.